package com.microexam.sunorder.service.impl;

import com.microexam.suncommon.domain.Order;
import com.microexam.sunorder.mapper.OrderMapper;
import com.microexam.sunorder.service.IOrderService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.util.List;

/**
 * @author gaopeng
 * @create 2020/04/2020/4/8 10:50:01
 */
@Service
@Transactional
public class OrderServiceImpl implements IOrderService {
    @Autowired
    private OrderMapper orderMapper;

    public List<Order> getAllOrders() {
        return orderMapper.getOrders();
    }
    public void addOrders(Order order){
        orderMapper.addOrder(order);
    }
}
